<{include file="./management/pageheader.htm" }> 
<link href="css/boxy.css" rel="stylesheet" type="text/css" />
<style type="text/css" >
input{ display:none;position:relative; margin-top:0px;}
</style>
<form method="post" action="" name="listForm">
<!-- start ads list -->
<div class="list-div" id="listDiv">
<table cellpadding="3" cellspacing="1">
  <tr>
    <th>链接名称</th>
    <th>链接地址</th>
    <th>链接logo</th>
    <th>显示顺序</th>
    <th>操作</th>
  </tr>
  <tr>
  <{foreach from=$Datil item=link}>
  <tr>
    <td class="first-cell"><span  class="nameedit_<{$link.link_id}>" id="nameedit")"><{$link.link_name|escape:html}></span><input  type="text" name="textfield" id="textfield_<{$link.link_id}>" value="" /></td>
    <td align="left"><span><a href="<{$link.link_url}>" target="_blank"><{$link.link_url|escape:html}></a></span></td>
    <td align="center"><span><{$link.link_logo}></span></td>
    <td align="right"><span  class="linkedit_<{$link.link_id}>" id="linkedit"><{$link.show_order}></span></td>
    <td align="center"><span>
    <a href="<{$pageUrl}>&act=edit&id=<{$link.link_id}>" title="编辑"><img src="images/admin/icon_edit.gif" border="0" height="16" width="16" /></a>&nbsp;
    <a class="delConfirm" href="<{$pageUrl}>&act=del&id=<{$link.link_id}>" title="删除"><img src="images/admin/icon_drop.gif" border="0" height="16" width="16" /></a></span></td>
  </tr>
  <{foreachelse}>
    <tr><td class="no-records" colspan="10"><{$lang.no_links}></td></tr>
  <{/foreach}>
  <tr>
    <td align="right" nowrap="true" colspan="10"><{include file="./management/page.htm"}></td>
  </tr>
</table>

</div>
<!-- end ad_position list -->
</form>
<{insert_scripts files="./js/jquery.min.js,admin.js,jquery.boxy.js"}>
<script type="text/javascript">
$(function(){
//	$("span[class^='nameedit'] ,span[class^='linkedit']").live("click",function(){
//		id=$(this).attr("class").replace('nameedit_','');
//		id=$(this).attr("class").replace('linkedit_','');
//		$(this).after('<input  type="text" name="textfield" id="textfield_'+id+'" value="'+$(this).html()+'" />');
//		$("#textfield_"+id).focus();
//		$(this).hide();
//	});
//	$("input[id^='textfield']").live("blur",function(){
//		id=$(this).attr("id").replace('link_','');
//		$(this).before('<span class="listedit_'+id+'"></span>');
//		$(".listedit_"+id).html($(this).val());
//		$(this).remove();

//$.post('./index.php',{c:"admin",a:"sysconfig",mod:"link",act:"modify",id:id,data:$(this).val()},function(data){
//	alert(data);
//	});
//	});	
//$("input").hide();
//$("span[class^='nameedit'] ,span[class^='linkedit']").live("click",function(){
//id=$(this).attr("class").replace($(this).attr("id")+"_",'');
//
//$(this).next("input").toggle();
//$(this).next("input").val($(this).html());	
//$(this).next("input").focus();
//$(this).toggle("slow");
//	})
//})
//$("input").blur(function(){
//$(this).fadeOut("fast");
//$(this).prev("span").html($(this).val());	
//$(this).prev("span").fadeIn("fast");
	});
</script>
<{include file="./management/pagefooter.htm"}>